package com.four.controller;

import com.four.entity.R;
import com.four.entity.Student;
import com.four.service.IStudentService;
import com.four.service.impl.StudentServiceImpl;
import com.qf.framwork.base.BaseServlet;

import javax.servlet.annotation.WebServlet;


/**
 * 学生的Controller
 * @author HZM
 * @version 2023/2/23
 */
@WebServlet("/StudentController")
public class StudentController extends BaseServlet {

    private IStudentService  studentService = new StudentServiceImpl();

    /**
     * 注册学生的Controller
     * @param student
     * @return
     */
    public R register(Student student){

        int result = studentService.register(student);

        return new R().setStatus(result);
    }

}
